package com.nontax.test.accept;

import com.alibaba.fastjson.JSON;
import com.nontax.test.common.domain.StdRespParameter;
import com.nontax.test.common.domain.StdRestAppInfo;
import com.nontax.test.common.domain.StdRestParameter;
import com.nontax.test.common.exception.BusinessException;
import com.nontax.test.epay.dto.AcctFundsCollectInfoDTO;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

@Controller
@Slf4j
public class AcceptController {

    @RequestMapping({"/nontax-revenue/financeRest/fundsCollect/acceptAcctFundsCollect.do",
            "/nontax-revenue/financeRest/payCapitalReconcile/acceptAcctFundsReconcile.do","/common/data"})
    @ResponseBody
    public StdRespParameter acceptCollectInfo(@RequestBody StdRestParameter stdRestParameter){
        log.info("接收到的业务参数为：{}", JSON.toJSONString(stdRestParameter));
        try {
            return StdRespParameter.generate("success", null);
        } catch (Exception e) {
            throw new BusinessException();
        }
    }
}
